3.102 \(\int \frac{x (a+b \log (c x^n))^2}{(d+e x)^2} \, dx\)

Optimal. Leaf size=143 \[ \frac{2 b n \text{PolyLog}\left (2,-\frac{e x}{d}\right ) \left (a+b \log \left (c x^n\right )\right )}{e^2}+\frac{2 b^2 n^2 \text{PolyLog}\left (2,-\frac{e x}{d}\right )}{e^2}-\frac{2 b^2 n^2 \text{PolyLog}\left (3,-\frac{e x}{d}\right )}{e^2}+\frac{2 b n \log \left (\frac{e x}{d}+1\right ) \left (a+b \log \left (c x^n\right )\right )}{e^2}+\frac{\log \left (\frac{e x}{d}+1\right ) \left (a+b \log \left (c x^n\right )\right )^2}{e^2}-\frac{x \left (a+b \log \left (c x^n\right )\right )^2}{e (d+e x)} \]

[Out]

-((x*(a + b*Log[c*x^n])^2)/(e*(d + e*x))) + (2*b*n*(a + b*Log[c*x^n])*Log[1 + (e*x)/d])/e^2 + ((a + b*Log[c*x^
n])^2*Log[1 + (e*x)/d])/e^2 + (2*b^2*n^2*PolyLog[2, -((e*x)/d)])/e^2 + (2*b*n*(a + b*Log[c*x^n])*PolyLog[2, -(
(e*x)/d)])/e^2 - (2*b^2*n^2*PolyLog[3, -((e*x)/d)])/e^2

________________________________________________________________________________________

Rubi [A]  time = 0.201671, antiderivative size = 143, normalized size of antiderivative = 1., number of steps used = 8, number of rules used = 6, integrand size = 21, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.286, Rules used = {2353, 2318, 2317, 2391, 2374, 6589} \[ \frac{2 b n \text{PolyLog}\left (2,-\frac{e x}{d}\right ) \left (a+b \log \left (c x^n\right )\right )}{e^2}+\frac{2 b^2 n^2 \text{PolyLog}\left (2,-\frac{e x}{d}\right )}{e^2}-\frac{2 b^2 n^2 \text{PolyLog}\left (3,-\frac{e x}{d}\right )}{e^2}+\frac{2 b n \log \left (\frac{e x}{d}+1\right ) \left (a+b \log \left (c x^n\right )\right )}{e^2}+\frac{\log \left (\frac{e x}{d}+1\right ) \left (a+b \log \left (c x^n\right )\right )^2}{e^2}-\frac{x \left (a+b \log \left (c x^n\right )\right )^2}{e (d+e x)} \]

Antiderivative was successfully verified.

[In]

Int[(x*(a + b*Log[c*x^n])^2)/(d + e*x)^2,x]

[Out]

-((x*(a + b*Log[c*x^n])^2)/(e*(d + e*x))) + (2*b*n*(a + b*Log[c*x^n])*Log[1 + (e*x)/d])/e^2 + ((a + b*Log[c*x^
n])^2*Log[1 + (e*x)/d])/e^2 + (2*b^2*n^2*PolyLog[2, -((e*x)/d)])/e^2 + (2*b*n*(a + b*Log[c*x^n])*PolyLog[2, -(
(e*x)/d)])/e^2 - (2*b^2*n^2*PolyLog[3, -((e*x)/d)])/e^2

Rule 2353

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^(r_.))^(q_.), x_Symbol]
:> With[{u = ExpandIntegrand[(a + b*Log[c*x^n])^p, (f*x)^m*(d + e*x^r)^q, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[
{a, b, c, d, e, f, m, n, p, q, r}, x] && IntegerQ[q] && (GtQ[q, 0] || (IGtQ[p, 0] && IntegerQ[m] && IntegerQ[r
]))

Rule 2318

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/((d_) + (e_.)*(x_))^2, x_Symbol] :> Simp[(x*(a + b*Log[c*x^n])
^p)/(d*(d + e*x)), x] - Dist[(b*n*p)/d, Int[(a + b*Log[c*x^n])^(p - 1)/(d + e*x), x], x] /; FreeQ[{a, b, c, d,
 e, n, p}, x] && GtQ[p, 0]

Rule 2317

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/((d_) + (e_.)*(x_)), x_Symbol] :> Simp[(Log[1 + (e*x)/d]*(a +
b*Log[c*x^n])^p)/e, x] - Dist[(b*n*p)/e, Int[(Log[1 + (e*x)/d]*(a + b*Log[c*x^n])^(p - 1))/x, x], x] /; FreeQ[
{a, b, c, d, e, n}, x] && IGtQ[p, 0]

Rule 2391

Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> -Simp[PolyLog[2, -(c*e*x^n)]/n, x] /; FreeQ[{c, d,
 e, n}, x] && EqQ[c*d, 1]

Rule 2374

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :> -Sim
p[(PolyLog[2, -(d*f*x^m)]*(a + b*Log[c*x^n])^p)/m, x] + Dist[(b*n*p)/m, Int[(PolyLog[2, -(d*f*x^m)]*(a + b*Log
[c*x^n])^(p - 1))/x, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 0] && EqQ[d*e, 1]

Rule 6589

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rubi steps

\begin{align*} \int \frac{x \left (a+b \log \left (c x^n\right )\right )^2}{(d+e x)^2} \, dx &=\int \left (-\frac{d \left (a+b \log \left (c x^n\right )\right )^2}{e (d+e x)^2}+\frac{\left (a+b \log \left (c x^n\right )\right )^2}{e (d+e x)}\right ) \, dx\\ &=\frac{\int \frac{\left (a+b \log \left (c x^n\right )\right )^2}{d+e x} \, dx}{e}-\frac{d \int \frac{\left (a+b \log \left (c x^n\right )\right )^2}{(d+e x)^2} \, dx}{e}\\ &=-\frac{x \left (a+b \log \left (c x^n\right )\right )^2}{e (d+e x)}+\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{e x}{d}\right )}{e^2}-\frac{(2 b n) \int \frac{\left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{e x}{d}\right )}{x} \, dx}{e^2}+\frac{(2 b n) \int \frac{a+b \log \left (c x^n\right )}{d+e x} \, dx}{e}\\ &=-\frac{x \left (a+b \log \left (c x^n\right )\right )^2}{e (d+e x)}+\frac{2 b n \left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{e x}{d}\right )}{e^2}+\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{e x}{d}\right )}{e^2}+\frac{2 b n \left (a+b \log \left (c x^n\right )\right ) \text{Li}_2\left (-\frac{e x}{d}\right )}{e^2}-\frac{\left (2 b^2 n^2\right ) \int \frac{\log \left (1+\frac{e x}{d}\right )}{x} \, dx}{e^2}-\frac{\left (2 b^2 n^2\right ) \int \frac{\text{Li}_2\left (-\frac{e x}{d}\right )}{x} \, dx}{e^2}\\ &=-\frac{x \left (a+b \log \left (c x^n\right )\right )^2}{e (d+e x)}+\frac{2 b n \left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{e x}{d}\right )}{e^2}+\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{e x}{d}\right )}{e^2}+\frac{2 b^2 n^2 \text{Li}_2\left (-\frac{e x}{d}\right )}{e^2}+\frac{2 b n \left (a+b \log \left (c x^n\right )\right ) \text{Li}_2\left (-\frac{e x}{d}\right )}{e^2}-\frac{2 b^2 n^2 \text{Li}_3\left (-\frac{e x}{d}\right )}{e^2}\\ \end{align*}

Mathematica [A]  time = 0.123893, size = 142, normalized size = 0.99 \[ \frac{2 b n \text{PolyLog}\left (2,-\frac{e x}{d}\right ) \left (a+b \log \left (c x^n\right )\right )+2 b^2 n^2 \text{PolyLog}\left (2,-\frac{e x}{d}\right )-2 b^2 n^2 \text{PolyLog}\left (3,-\frac{e x}{d}\right )+2 b n \log \left (\frac{e x}{d}+1\right ) \left (a+b \log \left (c x^n\right )\right )+\frac{d \left (a+b \log \left (c x^n\right )\right )^2}{d+e x}+\log \left (\frac{e x}{d}+1\right ) \left (a+b \log \left (c x^n\right )\right )^2-\left (a+b \log \left (c x^n\right )\right )^2}{e^2} \]

Antiderivative was successfully verified.

[In]

Integrate[(x*(a + b*Log[c*x^n])^2)/(d + e*x)^2,x]

[Out]

(-(a + b*Log[c*x^n])^2 + (d*(a + b*Log[c*x^n])^2)/(d + e*x) + 2*b*n*(a + b*Log[c*x^n])*Log[1 + (e*x)/d] + (a +
 b*Log[c*x^n])^2*Log[1 + (e*x)/d] + 2*b^2*n^2*PolyLog[2, -((e*x)/d)] + 2*b*n*(a + b*Log[c*x^n])*PolyLog[2, -((
e*x)/d)] - 2*b^2*n^2*PolyLog[3, -((e*x)/d)])/e^2

________________________________________________________________________________________

Maple [F]  time = 0.7, size = 0, normalized size = 0. \begin{align*} \int{\frac{x \left ( a+b\ln \left ( c{x}^{n} \right ) \right ) ^{2}}{ \left ( ex+d \right ) ^{2}}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(a+b*ln(c*x^n))^2/(e*x+d)^2,x)

[Out]

int(x*(a+b*ln(c*x^n))^2/(e*x+d)^2,x)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} a^{2}{\left (\frac{d}{e^{3} x + d e^{2}} + \frac{\log \left (e x + d\right )}{e^{2}}\right )} + \int \frac{b^{2} x \log \left (x^{n}\right )^{2} + 2 \,{\left (b^{2} \log \left (c\right ) + a b\right )} x \log \left (x^{n}\right ) +{\left (b^{2} \log \left (c\right )^{2} + 2 \, a b \log \left (c\right )\right )} x}{e^{2} x^{2} + 2 \, d e x + d^{2}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*log(c*x^n))^2/(e*x+d)^2,x, algorithm="maxima")

[Out]

a^2*(d/(e^3*x + d*e^2) + log(e*x + d)/e^2) + integrate((b^2*x*log(x^n)^2 + 2*(b^2*log(c) + a*b)*x*log(x^n) + (
b^2*log(c)^2 + 2*a*b*log(c))*x)/(e^2*x^2 + 2*d*e*x + d^2), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{b^{2} x \log \left (c x^{n}\right )^{2} + 2 \, a b x \log \left (c x^{n}\right ) + a^{2} x}{e^{2} x^{2} + 2 \, d e x + d^{2}}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*log(c*x^n))^2/(e*x+d)^2,x, algorithm="fricas")

[Out]

integral((b^2*x*log(c*x^n)^2 + 2*a*b*x*log(c*x^n) + a^2*x)/(e^2*x^2 + 2*d*e*x + d^2), x)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{x \left (a + b \log{\left (c x^{n} \right )}\right )^{2}}{\left (d + e x\right )^{2}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*ln(c*x**n))**2/(e*x+d)**2,x)

[Out]

Integral(x*(a + b*log(c*x**n))**2/(d + e*x)**2, x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (b \log \left (c x^{n}\right ) + a\right )}^{2} x}{{\left (e x + d\right )}^{2}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*log(c*x^n))^2/(e*x+d)^2,x, algorithm="giac")

[Out]

integrate((b*log(c*x^n) + a)^2*x/(e*x + d)^2, x)